Xbasic

HTTP_POST_PAGE2 Function

Syntax

Page_Text as C = http_post_page2(url as C [,post_body as B [,include_headers as L [,timeout as N]]])

Arguments

urlCharacter

The address of the server that will receive your data.

post_bodyBinary

Default = " ". The parameters you wish to send. The size of this field is unlimited.

include_headersLogical

Default = .F. (do not return headers). Allows the programmer to have the function return the headers along with the response body.

timeoutNumeric

Default = . Specifies the time, in seconds, after which the function should time out if a complete response has not been received from the server.

Returns

Page_TextCharacter

The HTML text of the selected page. Null if the server cannot be contacted.

Description

Use the HTTP method POST to retrieve the specified URL

HTTP_POST_PAGE2() is not server-safe and cannot be used in an A5W environment.

The HTTP_POST_PAGE2() function extends the HTTP_POST Function to support XML transfers. The HTTP_POST() function downloads from URL using HTTP/1.1 POST.

HTTP_POST_PAGE2() uses a Microsoft component named IXMLHTTPRequest. If the certificate does not match, the object aborts the connection.

See HTTP_GET_PAGE2 Function for an example.

Limitations

Desktop Applications Only

See Also